package com.ctshk.rpc.order.air.service.app;

import com.ctshk.common.model.TokenUser;
import com.ctshk.common.req.pay.NotifyConsumeReq;
import com.ctshk.rpc.order.air.dto.app.OrderDetailDTO;
import com.ctshk.rpc.order.air.req.AirOrderCancelReq;
import com.ctshk.rpc.order.air.req.app.AddOrderReq;
import com.ctshk.rpc.order.air.req.app.AppPayOrderReq;

/**
 * @BelongsProject: ctshk-cloud
 * @BelongsPackage: com.ctshk.rpc.order.air.service.app
 * @Author: hef
 * @CreateTime: 2021-05-20 14:40
 * @Description: APP机票订单
 */
public interface IAirProductOrderService {
    /**
     * 新增订单
     * @param req
     * @param currentUser
     * @return
     */
    Long addOrder(AddOrderReq req, TokenUser currentUser);

    /**
     * app支付订单
     * @param req
     * @param currentUser
     * @return
     */
    Object payOrder(AppPayOrderReq req, TokenUser currentUser);

    /**
     * 支付回调
     * @param req
     * @return
     */
    boolean payCallback(NotifyConsumeReq req);

    /**
     * 取消订单
     * @param req
     * @param currentUser
     * @return
     */
    boolean cancelOrder(AirOrderCancelReq req, TokenUser currentUser);

    /**
     * 获取订单详情
     * @param orderId
     * @return
     */
    OrderDetailDTO getOrderDetail(Long orderId);
}
